<HTML><HEAD><TITLE>atom(?Atom)</TITLE>
</HEAD><BODY>[ <A HREF="index.html">Type Testing</A> | <A HREF="../../index.html">Reference Manual</A> | <A HREF="../../fullindex.html">Alphabetic Index</A> ]
<H1>atom(?Atom)</H1>
Succeeds if Atom is a Prolog atom.


<DL>
<DT><EM>Atom</EM></DT>
<DD>Prolog term.
</DD>
</DL>
<H2>Description</H2>

    Used to test whether Atom is an atom.
    Note that this includes the empty list [].
<P>

<H3>Modes and Determinism</H3><UL>
<LI>atom(?) is semidet
</UL>
<H3>Fail Conditions</H3>
Fails if Atom is not an atom
<H2>Examples</H2>
<PRE>
Success:
        atom(atom).
        atom('Anything').
        atom(*).
        atom([]).
        atom(#).
        atom($).
        atom(/).
        atom(\).

Fail:
        atom(1).
        atom(this(is,a,structure)).
        atom(X).



</PRE>
<H2>See Also</H2>
<A HREF="../../kernel/typetest/var-1.html">var / 1</A>, <A HREF="../../kernel/typetest/is_list-1.html">is_list / 1</A>, <A HREF="../../kernel/typetest/callable-1.html">callable / 1</A>, <A HREF="../../kernel/typetest/type_of-2.html">type_of / 2</A>
</BODY></HTML>
